package com.jy.framework.constant;

/**
 * 用户区域
 * @author JuiceYan
 * @date 2018/12/20/020
 */
public enum UserAreaEnum {
    YN(530000,"云南省");
    private int code;
    private String value;
    UserAreaEnum(int code, String value) {
        this.code = code;
        this.value = value;
    }

    public int getCode() {
        return  code;
    }

    public  String getValue() {
        return value;
    }

    public static UserAreaEnum codeOf(int index) {
        for (UserAreaEnum userType :values()) {
            if (userType.code == index) {
                return userType;
            }
        }
        return null;
    }

}
